#ifndef _EK_IPS_H_
#define _EK_IPS_H_

extern const struct mutex_t initalized_mutex;

void mutex_init(volatile struct mutex_t *mutex);
int  mutex_lock(volatile struct mutex_t *mutex);
void mutex_unlock(volatile struct mutex_t *mutex);
bool mutex_trylock(volatile struct mutex_t *mutex);

extern const struct semaphore_t initalized_semaphore;

void semaphore_init(volatile struct semaphore_t *sem);
void semaphore_wait(volatile struct semaphore_t *sem);
void semaphore_notify(volatile struct semaphore_t *sem);
void semaphore_clear(volatile struct semaphore_t *sem, int count);

#endif /* _EK_IPS_H_ */
